package cn.enjoy.mapstruct.mapconvert;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;

/**
 * @author K
 * @date 2021/8/3 上午10:27
 */
public class DateTransform {

    public static LocalDateTime strToDate(String str) {
        DateTimeFormatter df = DateTimeFormatter.ofPattern("yyy-MM-dd HH:mm:ss");

        return LocalDateTime.parse(str, df);
    }

}